import type { NextConfig } from "next";

/** @type {import('next').NextConfig} */
const nextConfig: NextConfig = {
  /* config options here */
  reactStrictMode: true,
  webpack: (config, { isServer }) => {
    if (!isServer) {
      // 在客户端忽略这些 Node.js 模块
      config.resolve.fallback = {
        ...config.resolve.fallback,
        'proxy-agent': false,
        'urllib': false,
        'fs': false,
        'path': false,
        'os': false,
      };
    }
    return config;
  },
};

export default nextConfig;
